home *** CD-ROM | disk | FTP | other *** search
/ Commodore Disk User Volume 3 #6 / Commodore_Disk_User_Vol.3_6_1990_-.d64 / bar prompts (.txt) < prev    next >
Commodore BASIC  |  2022-10-26  |  4KB  |  183 lines

  1. 100 rem *****************************
  2. 105 rem *                           *
  3. 110 rem *        bar prompts        *
  4. 115 rem *                           *
  5. 120 rem *   (c) 1989 p. bastings    *
  6. 125 rem *                           *
  7. 130 rem *   poke 700,left margin    *
  8. 135 rem *   poke 701,bar lenght     *
  9. 140 rem *   poke 702,line number x  *
  10. 145 rem *   poke 703,line number y  *
  11. 150 rem *   poke 7..,line number z  *
  12. 155 rem *   poke 7..,255  end       *
  13. 160 rem *                           *
  14. 165 rem *   sys 52985     start     *
  15. 170 rem *   peek(2)=choice number   *
  16. 175 rem *                           *
  17. 180 rem *   if error in parameters  *
  18. 185 rem *   then 'illegal quantity  *
  19. 190 rem *   error in line ..'       *
  20. 195 rem *                           *
  21. 200 rem *****************************
  22. 205 :
  23. 210 :gosub745      :rem instal code
  24. 215 :poke 53280,11 :rem set border
  25. 220 :poke 53281,11 :rem set background
  26. 225 :
  27. 230 :dim m1(4)     :rem array menu 1
  28. 235 :m1(0)=3       :rem line number
  29. 240 :m1(1)=4
  30. 245 :m1(2)=5
  31. 250 :m1(3)=6
  32. 255 :m1(4)=255     :rem end of bars
  33. 260 :
  34. 265 :dim m2(17)    :rem array menu 2
  35. 270 :for i=0 to 16
  36. 275 :    m2(i)=i+4 :rem line numbers
  37. 280 :next i
  38. 285 :m2(i)=255     :rem end of bars
  39. 290 :
  40. 295 :poke 700,15   :rem left margin
  41. 300 :poke 701,10   :rem bar lenght
  42. 305 :for i=0 to 4  :rem instal values
  43. 310 :    poke 702+i,m1(i)
  44. 315 :next i
  45. 320 :
  46. 325 :print"[147]"spc(12)"bar-prompts demo"
  47. 330 :printspc(14)"[213][192][192][192][192][192][192][192][192][192][192][201]"
  48. 335 :printspc(14)"[221]border    [221]"
  49. 340 :printspc(14)"[221]background[221]"
  50. 345 :printspc(14)"[221]directory [221]"
  51. 350 :printspc(14)"[221]exit demo [221]"
  52. 355 :printspc(14)"[202][192][192][192][192][192][192][192][192][192][192][203]"
  53. 360 :
  54. 365 :printspc(90)"use crsr up or down"
  55. 370 :printspc(49)"press return to select"
  56. 375 :
  57. 380 :sys52985     :rem start prompts
  58. 385 :on peek(2)gosub 400,470,550,735
  59. 390 :goto 295
  60. 395 :
  61. 400 :ch=1:gosub 775:rem draw menu 2
  62. 405 :
  63. 410 :poke 700,3     :rem left margin
  64. 415 :poke 701,9     :rem bar lenght
  65. 420 :for i=0 to 17  :rem instal values
  66. 425 :    poke702+i,m2(i)
  67. 430 :next i
  68. 435 :
  69. 440 :sys 52985      :rem start prompts
  70. 445 :if peek(2)=17 then return
  71. 450 :
  72. 455 :poke 53280,peek(2)-1
  73. 460 :goto400
  74. 465 :
  75. 470 :ch=2:gosub 775:rem draw menu 2
  76. 475 :
  77. 480 :poke 700,27    :rem left margin
  78. 485 :poke 701,9     :rem bar lenght
  79. 490 :for i=0 to 17  :rem instal values
  80. 495 :    poke702+i,m2(i)
  81. 500 :next i
  82. 505 :
  83. 510 :sys 52985      :rem start prompts
  84. 515 :if peek(2)=17 then return
  85. 520 :
  86. 525 :poke 53281,peek(2)-1
  87. 530 :goto 470
  88. 535 :
  89. 540 :
  90. 545 :
  91. 550 :print"[147]"
  92. 555 :open1,8,0:close1
  93. 560 :if st=-128 then print"drive off line !":goto 650
  94. 565 :z$=chr$(0)
  95. 570 :open1,8,0,"$"
  96. 575 :k=25
  97. 580 :get#1,a$,a$
  98. 585 :fori=0 to 9
  99. 590 :    get#1,a$,a$,a$,b$
  100. 595 :    i=st
  101. 600 :    printasc(a$+z$)+asc(b$+z$)*256;
  102. 605 :    forj=0 to k
  103. 610 :        get#1,a$
  104. 615 :        printa$;
  105. 620 :    next j
  106. 625 :    k=27
  107. 630 :    print
  108. 635 :    i=st
  109. 640 :next i
  110. 645 :close1
  111. 650 :poke 700,0    :rem left margin
  112. 655 :poke 701,40   :rem bar lenght
  113. 660 :poke 702,24   :rem line 24
  114. 665 :poke 703,255  :rem end
  115. 670 :poke 211,0    :rem set cursor
  116. 675 :poke 214,24
  117. 680 :sys 58732
  118. 685 :print"press return to go back to menu";
  119. 690 :sys52985
  120. 695 :
  121. 700 :poke 700,15
  122. 705 :poke 701,10
  123. 710 :for i=o to 4
  124. 715 :    poke 702+i,m1(i)
  125. 720 :next i
  126. 725 :return
  127. 730 :
  128. 735 :end
  129. 740 :
  130. 745 :for i=52985 to 53216
  131. 750 :    read a
  132. 755 :    poke i,a
  133. 756 :    poke 53280,a
  134. 760 :next i
  135. 765 :return
  136. 770 :
  137. 775 :if ch=1 then c=2
  138. 780 :if ch=2 then c=26
  139. 785 :l=3
  140. 790 :poke211,c:poke214,l:sys58732
  141. 795 :print"[213][192][192][192][192][192][192][192][192][192][201]"
  142. 800 :for i=0 to 15
  143. 805 :    printspc(c)"[221]colour ";
  144. 810 :    if i<10 then printstr$(i)"[146][221]"
  145. 815 :    if i>9  then printright$(str$(i),2)"[146][221]"
  146. 820 :next i
  147. 825 :printspc(c)"[221]exit     [146][221]"
  148. 830 :printspc(c)"[202][192][192][192][192][192][192][192][192][192][203]"
  149. 835 :return
  150. 840 :
  151. 845 data169,039,205,188,002,176,003,076
  152. 850 data072,178,173,189,002,240,248,024
  153. 855 data109,188,002,133,002,169,040,197
  154. 860 data002,144,236,169,190,133,253,160
  155. 865 data002,132,254,136,136,177,253,133
  156. 870 data002,169,024,197,002,144,216
  157. 875 data240,023,200,192,025,240,019,177
  158. 880 data253,201,255,240,017,170,165,002
  159. 885 data134,002,197,002,144,236,076,072
  160. 890 data178,200,169,255,145,253,041,000
  161. 895 data133,002
  162. 900 data160,000,177,253,200,201,255,208
  163. 905 data249,136,140,187,002
  164. 910 data160,000,140,186,002,177,253,141
  165. 915 data185,002,032,186,207,173,188,002
  166. 920 data024,101,251,144,002,230,252,133
  167. 925 data251,032,210,207
  168. 930 data032,228,255,197,002,240,249,133
  169. 935 data002,201,017,240,038,201,145,240
  170. 940 data011,201,013,208,235
  171. 945 data172,186,002,200,132,002,096
  172. 950 data032,210,207,172,186,002,208,006
  173. 955 data172,187,002,140,186,002,206,186
  174. 960 data002,172,186,002,076,092,207
  175. 965 data032,210,207,172,186,002,200,204
  176. 970 data187,002,208,002,160,000,140,186
  177. 975 data002,076,092,207
  178. 980 data169,000,170,160,004,236,185,002
  179. 985 data240,009,232,024,105,040,144,245
  180. 990 data200,208,242,133,251,132,252,096
  181. 995 data160,000,177,251,073,128,145,251
  182. 1000 data200,204,189,002,208,244,096
  183.